<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>第一题</title>
</head>

<body>
    <script>
        function getChengji() {
            let shu = +prompt(`请输入随机两个数的乘积`)
            let arr = [1, 2, 3, 8, 9]
            console.log(arr)
            for (let i = 0; i < arr.length; i++) {
                for (let j = i; j < arr.length; j++) {
                    let num = arr[i] * arr[j]
                    if (shu === num) {
                        return [arr[i], arr[j]]
                    }
                }
            }
            return false
        }
        let num = getChengji()
        console.log(num)
    </script>
</body>

</html>